{% extends "base.html" %}
{% block page %}
    <div class="div"><p>线上项目进度</p></div>
    <div class="table table-hover table-striped" align="center" style="margin-top: 3%">
        <div class="table-responsive">
            <table class="table">
                <thead>
                    <tr>
                        <th>线上项目</th>
                        <th></th>
                        <th>开发进度</th>
                        <th></th>
                        <th>测试进度</th>
                        <th></th>
                        <th>发布进度</th>
                        <th>最新版本</th>
                    </tr>
                </thead>
                <tbody>
                    {% for project in Projects %}
                        <tr>
                            <td><span class="icon-folder-open"></span>{{ project }}</td>
                            <td><span class="icon-arrow-right"></span></td>
                            {% set Info = Projects[project] %}
                                {% if Info[1] %}
                                    <td style="color: #5bb75b"><span class="icon-ok"></span><a href="#" data-toggle="tooltip" title="用时{{ Info[0] }}天">已完成</a></td>
                                    <td><span class="icon-arrow-right"></span></td>
                                {% else %}
                                    {% set date = Info[0] - 1 %}
                                    <td style="color: orangered"><span class="icon-flag"></span><a href="#" data-toggle="tooltip" title="用时{{ date }}天">开发中</a></td>
                                    <td></td>
                                {% endif %}
                                {% if Info[2] %}
                                    <td style="color: #5bb75b"><span class=" icon-ok"></span><a href="#" data-toggle="tooltip" title="用时{{ Info[1] }}天">已完成</a></td>
                                    <td><span class="icon-arrow-right"></span></td>
                                {% elif Info[1] %}
                                    {% set date = Info[1] - 1 %}
                                    <td style="color:orangered"><span class="icon-flag"></span><a href="#" data-toggle="tooltip" title="用时{{ date }}天">测试中</a></td>
                                    <td></td>
                                {% else%}
                                    <td style="color:#9e9e9e"><span class="icon-remove"></span><a href="#">未开始</a></td>
                                    <td></td>
                                {% endif %}
                                {% if Info[2] %}
                                    {% set date = Info[2] - 1 %}
                                    <td style="color:#5bb75b"><span class="icon-ok"></span><a href="#" data-toggle="tooltip" title="{{ date }}天前上线">已完成</a></td>
                                {% else %}
                                    <td style="color:#9e9e9e"><span class="icon-remove"></span><a href="#">未开始</a></td>
                                {% endif %}
                                {% if Info[3] %}
                                    <td><span class="icon-tag"></span>{{ Info[3] }}</td>
                                {% else %}
                                    <td>无</td>
                                {% endif %}
                        </tr>
                    {% endfor %}
                </tbody>
            </table>
        </div>
    </div>
{% endblock page %}